<?php $this->load->view('layout/header'); ?>
<div class="container-fluid">
    <div class="row-fluid">
        <div class="span12">
            <h3 class="page-title">旅游产品<small> 产品类型</small></h3>
            <?php echo breadcrumb(array('tourismgoods/grid' => '旅游产品', 'tourismgoodscategory/grid' => '类别管理', 'tourismgoodscategoryattribute/grid/'.$category_id => '属性管理')); ?>
        </div>
    </div>
    <?php echo execute_alert_message() ?>
    <div class="row-fluid">
        <div class="span12">
            <div class="portlet box green">
                <div class="portlet-title">
                    <div class="caption"><i class="icon-reorder"></i>列表</div>
                    <div class="tools">
                        <a class="collapse" href="javascript:;"></a>
                        <a class="remove" href="javascript:;"></a>
                    </div>
                </div>
                <div class="portlet-body flip-scroll">
                    <div class="dataTables_wrapper form-inline">
                        <div class="clearfix">
                            <a href="<?php echo base_url('tourismgoodscategoryattribute/add/'.$category_id) ?>" class="add-button-link">
                                <div class="btn-group">
                                    <button class="btn green"><i class="icon-plus"></i> 添加</button>
                                </div>
                            </a>
                        </div>
                        <?php if ($result->num_rows() > 0) : ?>
                            <table class="table table-striped table-bordered table-hover">
                                <thead class="flip-content">
                                    <tr>
                                        <th>属性名</th>
                                        <th>属性值</th>
                                        <th>操作</th>
                                    </tr>
                                </thead>
                                <tbody>
                                <?php foreach ($result->result() as $item) : ?>
                                    <tr>
                                        <td><?php echo $item->attr_name; ?></td>
                                        <td><?php echo $this->tourism_goods_category_spec->getSpecStringByAttId($item->attr_id) ?></td>
                                        <td width="120">
                                            <a class="btn mini green" href="<?php echo base_url('tourismgoodscategoryattribute/edit/' . $item->attr_id); ?>">修改</a>
                                            <!--<a class="btn mini green" href="<?php echo base_url('tourismgoodscategoryattribute/delete/' . $item->attr_id . '?category_id=' . $item->category_id); ?>" onclick="return confirm('确定要删除？')"><i class="icon-trash"></i> 删除</a>-->
                                        </td>
                                    </tr>
                                <?php endforeach; ?>
                                </tbody>
                            </table>
                        <?php else: ?>
                            <div class="alert"><p>未找到数据。<p></div>
                        <?php endif ?>
                    </div>
                </div>
            </div>
        </div>
    </div>
</div>
<?php $this->load->view('layout/footer'); ?>